<?php
/*=============================================================================
|| ##################################################################
||	phpFoX Konsort
|| ##################################################################
||
||	Copyright		: (C) 2005-2007 PHPFOX Limited a Reality Fox Creation
||	Contact			: info@phpfox.com
||
||	- phpFoX and all of its source code and files are protected by Copyright Laws.
||
||	- The license for phpFoX permits you to install this software on a single domain (.com, .org, .net, etc.).
||
||	- You may also not remove this copyright screen which shows the copyright information and credits for phpFoX (RealityFOX Creations).
||
||	- phpFoX Konsort is NOT a FREE software - http://www.phpfox.com/license/
||
|| ##################################################################
=============================================================================*/

/* $File: ./site/public/gallery/_pre.php, $Author:  $ */

    //create tabs menu
    $aMenuItems = array(
    	'public.gallery.main'	=> App::format('menu.gallery.main'),
    	'public.gallery.rate'  => App::format('menu.gallery.rate'),
    	'public.gallery.battle'  => App::format('menu.gallery.battle'),
    	'public.gallery.featured' => App::format('menu.gallery.featured'),
        'public.account.submit.upload-pic' => App::format('menu.gallery.submit.upload-pic'),
        'public.account.myitems.edit-pic'  => App::format('menu.gallery.myitems.edit-pic'),
    );

    if ( App::getParam('section_rate') )
    {
    	unset($aMenuItems['public.gallery.rate']);
    }

    if ( App::getParam('section_battle') )
    {
    	unset($aMenuItems['public.gallery.battle']);
    }


    $aParams = array(
    	'sTemplate'  => 'TabbedMenu',
        'aMenuItems' => $aMenuItems,
        'sSearchUrl' => 'public.gallery.main'
    );


    $oCompMenu = App::getModuleComponent('Menu', 'Menu', $aParams);
    $srcTabbedMenu = $oCompMenu->process();

    $oTpl = &App::getTemplate();
    $oTpl->assignSrc(array(
    	'srcTabbedMenu' => $srcTabbedMenu,
    ));
?>